package persistence;

import java.io.Serializable;
import javax.persistence.*;
import java.util.Set;


/**
 * The persistent class for the Owner database table.
 * 
 */
@Entity
public class Owner implements Serializable {
	private static final long serialVersionUID = 1L;
	private int idOwner;
	private String cr;
	private String email;
	private String name;
	private Set<Firm_has_Owner> firmHasOwners;

    public Owner() {
    }


	@Id
	public int getIdOwner() {
		return this.idOwner;
	}

	public void setIdOwner(int idOwner) {
		this.idOwner = idOwner;
	}


	public String getCr() {
		return this.cr;
	}

	public void setCr(String cr) {
		this.cr = cr;
	}


	public String getEmail() {
		return this.email;
	}

	public void setEmail(String email) {
		this.email = email;
	}


	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}


	//bi-directional many-to-one association to Firm_has_Owner
	@OneToMany(mappedBy="owner")
	public Set<Firm_has_Owner> getFirmHasOwners() {
		return this.firmHasOwners;
	}

	public void setFirmHasOwners(Set<Firm_has_Owner> firmHasOwners) {
		this.firmHasOwners = firmHasOwners;
	}
	
}